package finalproject.bd1.model;

import java.io.Serializable;
import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;


/**
 * The persistent class for the employee database table.
 */
@Entity
@Table(name="employee")
public class Employee extends AbstractEntity implements Serializable {
	private static final long serialVersionUID = 1L;

//	@Id
//	@SequenceGenerator(name="EMPLOYEE_ID_GENERATOR", sequenceName="EMPLOYEE_ID_SEQ")
//	@GeneratedValue(strategy=GenerationType.SEQUENCE, generator="EMPLOYEE_ID_GENERATOR")
//	@Column(unique=true, nullable=false)
//	private Integer id;

	@Temporal(TemporalType.DATE)
	@Column(name="employee_admission_date")
	private Date employeeAdmissionDate;

	@Column(name="employee_cep", length=14)
	private String employeeCep;

	@Column(name="employee_city", length=30)
	private String employeeCity;

	@Column(name="employee_cpf", nullable=false, length=11)
	private String employeeCpf;

	@Column(name="employee_name", nullable=false, length=70)
	private String employeeName;

	@Column(name="employee_neighborhood", length=30)
	private String employeeNeighborhood;

	@Column(name="employee_phone1", length=15)
	private String employeePhone1;

	@Column(name="employee_phone2", length=15)
	private String employeePhone2;

	@Column(name="employee_position", nullable=false, length=50)
	private String employeePosition;

	@Column(name="employee_registry", nullable=false, length=10)
	private String employeeRegistry;

	@Temporal(TemporalType.DATE)
	@Column(name="employee_resignation_date")
	private Date employeeResignationDate;

	@Column(name="employee_salary", precision=131089)
	private BigDecimal employeeSalary;

	@Column(name="employee_street", length=50)
	private String employeeStreet;

	@Column(name="employee_uf", length=2)
	private String employeeUf;

	//bi-directional many-to-one association to ExecutionService
	@OneToMany(mappedBy="employee")
	private List<ExecutionService> executionServices;

	//bi-directional many-to-one association to OrderService
	@OneToMany(mappedBy="employee")
	private List<OrderService> orderServices;

	//bi-directional many-to-many association to Service
	@ManyToMany(mappedBy="employees")
	private List<Service> services;

	public Employee() {
	}

//	public Integer getId() {
//		return this.id;
//	}
//
//	public void setId(Integer id) {
//		this.id = id;
//	}

	public Date getEmployeeAdmissionDate() {
		return this.employeeAdmissionDate;
	}

	public void setEmployeeAdmissionDate(Date employeeAdmissionDate) {
		this.employeeAdmissionDate = employeeAdmissionDate;
	}

	public String getEmployeeCep() {
		return this.employeeCep;
	}

	public void setEmployeeCep(String employeeCep) {
		this.employeeCep = employeeCep;
	}

	public String getEmployeeCity() {
		return this.employeeCity;
	}

	public void setEmployeeCity(String employeeCity) {
		this.employeeCity = employeeCity;
	}

	public String getEmployeeCpf() {
		return this.employeeCpf;
	}

	public void setEmployeeCpf(String employeeCpf) {
		this.employeeCpf = employeeCpf;
	}

	public String getEmployeeName() {
		return this.employeeName;
	}

	public void setEmployeeName(String employeeName) {
		this.employeeName = employeeName;
	}

	public String getEmployeeNeighborhood() {
		return this.employeeNeighborhood;
	}

	public void setEmployeeNeighborhood(String employeeNeighborhood) {
		this.employeeNeighborhood = employeeNeighborhood;
	}

	public String getEmployeePhone1() {
		return this.employeePhone1;
	}

	public void setEmployeePhone1(String employeePhone1) {
		this.employeePhone1 = employeePhone1;
	}

	public String getEmployeePhone2() {
		return this.employeePhone2;
	}

	public void setEmployeePhone2(String employeePhone2) {
		this.employeePhone2 = employeePhone2;
	}

	public String getEmployeePosition() {
		return this.employeePosition;
	}

	public void setEmployeePosition(String employeePosition) {
		this.employeePosition = employeePosition;
	}

	public String getEmployeeRegistry() {
		return this.employeeRegistry;
	}

	public void setEmployeeRegistry(String employeeRegistry) {
		this.employeeRegistry = employeeRegistry;
	}

	public Date getEmployeeResignationDate() {
		return this.employeeResignationDate;
	}

	public void setEmployeeResignationDate(Date employeeResignationDate) {
		this.employeeResignationDate = employeeResignationDate;
	}

	public BigDecimal getEmployeeSalary() {
		return this.employeeSalary;
	}

	public void setEmployeeSalary(BigDecimal employeeSalary) {
		this.employeeSalary = employeeSalary;
	}

	public String getEmployeeStreet() {
		return this.employeeStreet;
	}

	public void setEmployeeStreet(String employeeStreet) {
		this.employeeStreet = employeeStreet;
	}

	public String getEmployeeUf() {
		return this.employeeUf;
	}

	public void setEmployeeUf(String employeeUf) {
		this.employeeUf = employeeUf;
	}

	public List<ExecutionService> getExecutionServices() {
		return this.executionServices;
	}

	public void setExecutionServices(List<ExecutionService> executionServices) {
		this.executionServices = executionServices;
	}

	public List<OrderService> getOrderServices() {
		return this.orderServices;
	}

	public void setOrderServices(List<OrderService> orderServices) {
		this.orderServices = orderServices;
	}

	public List<Service> getServices() {
		return this.services;
	}

	public void setServices(List<Service> services) {
		this.services = services;
	}
}